<?php
/**
 * Created by PhpStorm.
 * User: guokunsheng
 * Date: 2020/9/17
 * Time: 14:58
 */

namespace astrologer;

use think\Route;

/**
 * 占星师问答后台接口路由
 */

Route::group('astrologer/user', static function ()
{
    Route::post('/login', 'astrologer/Login/login');
    Route::post('/tellogin', 'astrologer/Login/telLogin');
    Route::post('/miniAppLogin', 'astrologer/Login/miniAppLogin');
    Route::post('/reg', 'astrologer/Login/regiest');
    Route::post('/reset_pwd', 'astrologer/Login/passwordReset');
    Route::get('/info', 'astrologer/User/info');
    Route::post('/bind_tel', 'astrologer/User/bindTel'); // 小程序绑定手机号
    Route::post('/logout', 'astrologer/User/logout');
    Route::get('/getVerifyCode', 'astrologer/login/getCode');
    Route::get('/compoleteInfo', 'astrologer/User/compoleteInfo');
    Route::post('/compoleteInfo', 'astrologer/User/compoleteInfo');
    Route::get('/getPlatformData', 'astrologer/User/getPlatformData');  // 获取平台培训考试规则
    Route::post('/platformTest', 'astrologer/AstrExamine/platformTest');    // 获取 ｜ 提交 平台培训考试结果
    Route::get('/platformResult', 'astrologer/User/platformResult');   // 获取平台培训考试状态
    Route::get('/getSubscribeQrcode', 'astrologer/User/getSubscribeQrcode');
    Route::get('/getAssessmentData', 'astrologer/AstrExamine/getAssessmentData');//获取占星师考试状态
    Route::post('/assessmentQuestion', 'astrologer/AstrExamine/getExamineQuestion');//获取问题&提交答案
    Route::post('/upload', 'astrologer/Upload/upload');// 上传图片
    Route::post('/search_bank_branch', 'astrologer/User/searchBankBranch');// 上传图片
    Route::get('/grade_change_recode', 'astrologer/User/gradeChangeRecode');
    Route::post('/unbind_zyhs', 'astrologer/User/unBindZyhsUser');  // 解绑准有好事
});

Route::group('astrologer/task', static function ()
{
    // 获取占星师可领取任务数量
    Route::get('/getTaskNum', 'astrologer/Task/getTaskNum');
    // 获取问题的状态
    Route::get('/getTaskIsCancle', 'astrologer/Task/getTaskIsCancle');
    // 获取占星师任务列表
    Route::get('/list', 'astrologer/Task/list');
    // 占星师接单
    Route::get('/get', 'astrologer/Task/get');
    // 占星师任务放弃
    Route::post('/discard', 'astrologer/Task/discard');
    // 占星师问题回答
    Route::post('/answer', 'astrologer/Task/answer');
    // 占星师问题备注
    Route::post('/note', 'astrologer/Task/note');
    // 占星师问题申诉
    Route::post('/complain', 'astrologer/Task/complain');
    // 占星师问题申诉进行取消
    Route::post('/cancelComplain', 'astrologer/Task/cancelComplain');
    // 获取占星师补充问题信息
    Route::get('/supplement_info', 'astrologer/Task/getSupplementInfo');

});


Route::group('astrologer/earnings', static function ()
{
    // 收益统计信息
    Route::get('/index', 'astrologer/Earnings/index');
    // 收益列表
    Route::get('/list', 'astrologer/Earnings/list');
    // 收益申诉
    Route::post('/complain', 'astrologer/Earnings/complain');
    // 提现列表
    Route::get('/getWithdrawalList', 'astrologer/Earnings/getWithdrawalList');

});

Route::group('astrologer/message', static function ()
{
    // 消息中心
    Route::get('/index', 'astrologer/Message/index');
    // 消息已读
    Route::post('/read', 'astrologer/Message/msgRead');
});

Route::group('astrologer/:ver', function ()
{
    // 问答 问题详情
    Route::get('/question/question_info', 'astrologer/:ver.Question/questionInfo');
    // 问答回答接口
    Route::post('/question/to_answer', 'astrologer/:ver.Question/toAnswer');
    // 获取 常见问题
    Route::get('question/get_faq', 'astrologer/:ver.Question/getFaq');
    // 接单列表
    Route::get('question/new_question_list', 'astrologer/:ver.Question/questionWaitingList');
    // 接单
    Route::post('question/astr_receiving', 'astrologer/:ver.Question/astrReceiving');
    // 弃答
    Route::post('question/discard_question', 'astrologer/:ver.Question/discardQuestion');
    // 获取问答 进行中｜已完成 列表
    Route::get('question/question_list', 'astrologer/:ver.Question/astrTaskList');
    // 获取追问取消任务标签
    Route::get('question/cannel_tag', 'astrologer/:ver.Question/getCannelTaskTag');
    // 占星师等级信息
    Route::get('user/level_info', 'astrologer/:ver.User/getUserLevelInfo');
    // 咨询师考试数据
    Route::get('user/getAssessmentData', 'astrologer/:ver.User/getAssessmentData');
    // 获取考试题目&提交答案
    Route::post('user/assessmentQuestion', 'astrologer/:ver.User/getExamineQuestion');
    // 能力分变动记录
    Route::get('user/grade_change_recode', 'astrologer/:ver.User/getGradeChangeRecode');
    // 取消追问任务
    Route::post('question/cannel_add_question', 'astrologer/:ver.Question/cannelAddQuestion');
    // 定制报告首页
    Route::get('task/list', 'astrologer/:ver.Task/list');
    // 问答历史
    Route::get('task/task_record_list', 'astrologer/:ver.Question/getAstrTaskRecordList');
    // 收益记录
    Route::get('earnings/list', 'astrologer/:ver.Earnings/list');
    // 获取面试详情数据
    Route::get('user/getInterviewData', 'astrologer/:ver.User/getInterviewData');
    // 申请｜取消面试申请
    Route::post('user/operate_interview', 'astrologer/:ver.User/operateInterview');

    Route::get('user/compoleteInfo', 'astrologer/:ver.User/compoleteInfo');
    Route::post('user/compoleteInfo', 'astrologer/:ver.User/compoleteInfo');

    // 定制报告首页
    Route::get('index/index', 'astrologer/:ver.Index/index');

    Route::get('user/info', 'astrologer/:ver.User/info');

    // 问答回答接口
    Route::post('/question/supplement_answer', 'astrologer/:ver.Question/supplementAnswer');
    // 放弃补充回答
    Route::post('/question/discard_complain_supplement_answer', 'astrologer/:ver.Question/discardComplainSupplementAnswer');

    //  ----------------------------- V4 -------------------------------------------
    Route::post('/login/tellogin', 'astrologer/:ver.Login/telLogin');   // 手机号登录
    Route::get('/login/get_code', 'astrologer/:ver.Login/getCode');   // 获取验证码

    Route::get('/consult/get_consult_chat_list', 'astrologer/:ver.Consult/getConsultChatList');   // 获取 咨询对话 列表
    Route::get('/consult/get_consult_chat_detail_record', 'astrologer/:ver.Consult/getConsultChatDetailRecord');   // 获取 对话详情记录 列表
    Route::post('/consult/send_consult_msg', 'astrologer/:ver.Consult/sendConsultMsg');   // 发送 咨询对话 信息
    Route::post('/consult/replay_consult_question', 'astrologer/:ver.Consult/replayConsultQuestion');   // 回复 咨询问题 答案
    Route::get('/consult/comment_list', 'astrologer/:ver.Consult/commentList');//评价列表
    Route::get('/consult/consult_msg_read', 'astrologer/:ver.Consult/consultChatMsgRead');// 咨询消息 已读
    Route::post('/consult/accept_rtc', 'astrologer/:ver.Consult/acceptRtc');   // 语音咨询 接听连麦
    Route::post('/consult/refuse_rtc', 'astrologer/:ver.Consult/refuseRtc');   // 语音咨询 挂断连线｜拒绝连线
    Route::get('/consult/get_cancel_reason', 'astrologer/:ver.Consult/getCancelReason');  //  获取故障挂断原因
    Route::get('/consult/get_rtc_consult_status_info', 'astrologer/:ver.Consult/getRtcConsultStatusInfo');  //  获取 连线咨询 状态信息
    Route::get('/consult/get_consult_task_list', 'astrologer/:ver.Consult/getConsultTaskList');  //  获取连线历史任务列表
    Route::get('/consult/get_consult_task_current', 'astrologer/:ver.Consult/getConsultTaskCurrent');  //  获取当前正在连麦的任务
    Route::get('/consult/rtc_chat_detail', 'astrologer/:ver.Consult/rtcChatDetail');  //  咨询详情
    Route::get('/consult/ranking_list', 'astrologer/:ver.Consult/getRankingList');  //  咨询师 排行榜

    Route::get('/app/upgrade', 'astrologer/:ver.AppUpgrade/index');  //  APP更新

    Route::post('/task/assign_task_change', 'astrologer/:ver.Task/assignTaskChange');   // 定制报告派单状态修改
    Route::get('/task/getTaskNum', 'astrologer/:ver.Task/getTaskNum');   // 获取占星师可领取任务数量

    Route::get('/astrolabe/astrologer', 'astrologer/:ver.AstrolabeController/astrolabe_astrologer');// 占星师后台-星盘接口
    Route::get('/astrologer/astroset', 'astrologer/:ver.AstrolabeController/astrologer_setting_index');// 占星师后台-星盘设置-获取星盘配置接口
    Route::post('/astrologer/astroset', 'astrologer/:ver.AstrolabeController/astrologer_setting_update');// 占星师后台-星盘设置-更新星盘配置接口
    Route::put('/astrologer/astroset', 'astrologer/:ver.AstrolabeController/astrologer_setting_restore');// 占星师后台-星盘设置-还原星盘配置接口


    //  ----------------------------- V4--咨询师App内置h5相关接口 -------------------------------------------
    Route::get('/app_inner/redirect', 'astrologer/:ver.AppInner/redirectUrl');//咨询师App内置h5转发地址
    Route::get('/app_inner/rtc_price_info', 'astrologer/:ver.User/rtcPriceInfo');//咨询师App内置h5：连线单价
    Route::get('/user/profileInfo', 'astrologer/:ver.User/profileInfo');//获取完善资料信息
    Route::put('/user/info', 'astrologer/:ver.User/modifyInfo');//修改个人信息
    Route::get('/user/home_page', 'astrologer/:ver.User/HomePage');//主页
    Route::get('/user/work_intro', 'astrologer/:ver.User/getWorkIntro');//获取营业介绍
    Route::put('/user/work_intro', 'astrologer/:ver.User/alterWorkStatus');//修改营业状态和营业介绍


    //  ----------------------------- V5---------------------------------------------
    Route::put('/consult/modify_price', 'astrologer/:ver.User/consultModifyPrice'); // 修改连线咨询 连线单价
    Route::get('level_growth/list', 'astrologer/:ver.AstrLevel/growthList');    // 咨询师等级成长明细
    Route::get('/astrolabe/question_astrologer', 'astrologer/:ver.AstrolabeController/questionAstrologer');    // 准有好事 - 问答 - 星盘接口


    //咨询师App内置h5转发地址
    Route::get('astrologer/app_inner/index', 'astrologer/AppInner/redirectUrl');
    Route::get('/app_inner/rtc_price_info', 'astrologer/:ver.AppInner/rtcPriceInfo');//连线单价
    //test
//    Route::get('/user/profileInfo', 'astrologer/:ver.AppInner/profileInfo');//用户资料信息
//    Route::post('/user/compoleteInfo', 'astrologer/:ver.AppInner/compoleteInfo');//更新用户资料信息
//    Route::get('/consult/get_consult_task_list', 'astrologer/:ver.AppInner/getConsultTaskList');//获取连线历史任务列表
//    Route::get('user/info', 'astrologer/:ver.AppInner/userInfo'); //问答tab和定制报告tab，获取的 完善资料 或者 绑定准了号 或者 考试通过列表
//    Route::get('index/index', 'astrologer/:ver.AppInner/reportIndex');//定制报告首页
//    Route::get('task/getTaskNum', 'astrologer/:ver.AppInner/reportGetTaskNumAndTaskListUpdate');// 获取可接任务数量和任务列表状态是否更新
//    Route::get('task/list', 'astrologer/:ver.AppInner/reportTaskList');//定制报告首页任务列表
//    Route::post('task/assign_task_change', 'astrologer/:ver.AppInner/reportTaskAssignChange');//定制报告首页任务列表
    //test
    //  ----------------------------- V6---------------------------------------------
    // 钱包 - 个人收益明细
    Route::get('earnings/list2', 'astrologer/:ver.Earnings/list2');
    // 提交/取消 提现申请
    Route::post('earnings/apply_withdraw', 'astrologer/:ver.Earnings/applyWithdraw');
    // 提现历史 - 提现列表
    Route::get('earnings/get_withdraw_history_list', 'astrologer/:ver.Earnings/getWithdrawHistoryList');
    // 获取提现信息
    Route::get('earnings/get_apply_withdraw_info', 'astrologer/:ver.Earnings/getApplyWithdrawInfo');
    // 结算历史 无分页 非提现列表
    Route::get('earnings/get_withdraw_list', 'astrologer/:ver.Earnings/getWithdrawalList');
    //检测邀请码是否已使用
    Route::get('user/get_invite_code_status', 'astrologer/:ver.User/checkAuthCode');
    //使用邀请码
    Route::post('user/invite_code_enter', 'astrologer/:ver.User/useAuthCode');
    //  ----------------------------- V7 ---------------------------------------------
    //  消息通知
    //  获取通知状态信息
    Route::get('push/get_notice', 'astrologer/:ver.Push/getNoticeInfo');
    //  设置通知状态信息
    Route::post('push/set_notice', 'astrologer/:ver.Push/setNoticeStatus');
    //  推送绑定
    Route::post('push/bind', 'astrologer/:ver.Push/bind');
    //获取默认对话
    Route::get('consult/default_chat', 'astrologer/:ver.User/defaultChat');
    //设置默认对话
    Route::put('consult/default_chat', 'astrologer/:ver.User/setDefaultChat');
    //获取资质证书列表
    Route::get('consult/certificate_list', 'astrologer/:ver.User/certificateList');
    //获取日期预约记录
    Route::get('consult/date_appointment', 'astrologer/:ver.Consult/dateReservationList');
    //获取全部预约记录
    Route::get('consult/appointment', 'astrologer/:ver.Consult/reservationList');
    //处理预约
    Route::put('consult/appointment', 'astrologer/:ver.Consult/handleReservation');
    //获取预约配置
    Route::get('consult/appointment_config', 'astrologer/:ver.Consult/getReservationConfig');
    //修改预约配置
    Route::put('consult/appointment_config', 'astrologer/:ver.Consult/setReservationConfig');
    // 获取新消息数量
    Route::get('consult/get_new_message_count', 'astrologer/:ver.Consult/getNewMessageCount');
    //  ----------------------------- V8 ---------------------------------------------
    //用户备注
    Route::put('consult/user_remark', 'astrologer/:ver.Consult/alterUserConsultRemark');
    //咨询备注信息
    Route::get('consult/remark', 'astrologer/:ver.Consult/consultRemark');
    //修改咨询备注信息
    Route::put('consult/remark', 'astrologer/:ver.Consult/alterConsultRemark');
});

